<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>Document</title>
  <style>
    * {
      box-sizing: border-box;
    }
    html,body{
      width: 100%;
      height: 100%;
      background-color: #353b48;
      overflow: hidden;
      margin: 0;
      padding: 0;
      display: flex;
      justify-content: center;
      align-items: center;
    }
    #loader{
      width: 550px;
    }
    .count{
      display: flex;
      justify-content: center;
      padding: 2rem 0;
      font-size: 2.5rem;
      color: #8aaaff;
    }
    .progress-bar{
      background-color: #e6eeff;
      width: 500px;
      height: 10px;
      border-radius: 50px;
      margin: auto;
      overflow: hidden;
    }
    .progress{
      background: linear-gradient(90deg,#8aaaff,#fa8cff);
      width: 0;
      height: 100px;
      border-radius: 5px;
    }
  </style>
</head>

<body>
  <div id="loader">
    <div class="count" id="contText">100%</div>
    <div class="progress-bar">
      <div class="progress" id="progress"></div>
    </div>
  </div>
  <script>
      let progr = document.getElementById("progress");
      let text = document.getElementById("contText");
      let counter = 5;
      let progress = 25;
      let id = setInterval(function(){
        if(progress == 500 && counter == 100){
          clearInterval(id)
        }else{
          progress += 5;
          counter += 1;
          progr.style.width = progress + "px";
          text.innerHTML = counter + "%";
        }
      },10)
  </script>
</body>

</html>